package com.isesol.ime.entity;

import com.fasterxml.jackson.annotation.*;
import com.isesol.ime.*;
import com.isesol.orm.jpa.*;

import javax.persistence.*;

/**
 * 报文已选参数
 *
 * @author Wang Jun
 */
@Entity
@Table(name = "msgparams", catalog = Constant.DB_SCHEME_MT)
@Access(AccessType.FIELD)
@JsonIdentityInfo(generator=ObjectIdGenerators.PropertyGenerator.class, property="id")
public class MessageParam extends IdEntity<Long>{

	/**
	 * 报文id
	 */
	@ManyToOne
	@JoinColumn(name="msg_id")
	private Message message;

	/**
	 * 已选参数id
	 */
	@ManyToOne
	@JoinColumn(name = "PARAM_ID")
	private Param param;

	public Param getParam(){

		return param;
	}

 	public void setParam(Param param){

		this.param = param;
	}

	public Message getMessage() {
		return message;
	}

	public void setMessage(Message message) {
		this.message = message;
	}
}
